<template>
  <div class="business">
    <navigation-bar></navigation-bar>
    <el-container>
      <!--    侧边栏-->
      <el-aside width="188px">
        <div class="title">业务桌面</div>
        <el-menu
          :default-active="activePath"
          class="el-menu-vertical-demo"
          router>
          <el-menu-item index="/business/order">
            <i class="el-icon-menu"></i>
            <span slot="title">订单管理</span>
          </el-menu-item>
          <el-submenu index="/business/companyService">
            <template slot="title">
              <i class="el-icon-location"></i>
              <span>产品管理</span>
            </template>
<!--            <el-menu-item index="/business/companyService">-->
<!--              <i class="el-icon-menu"></i>-->
<!--              <span slot="title">公司服务</span>-->
<!--            </el-menu-item>-->
            <el-menu-item index="/business/qualificationCertificate">
              <i class="el-icon-menu"></i>
              <span slot="title">资质证照</span>
            </el-menu-item>
            <el-menu-item index="/business/legalInstrument">
              <i class="el-icon-menu"></i>
              <span slot="title">法律文书</span>
            </el-menu-item>
            <el-menu-item index="/business/intellectualProperty">
              <i class="el-icon-menu"></i>
              <span slot="title">知识产权</span>
            </el-menu-item>
            <el-menu-item index="/business/legalConsult">
              <i class="el-icon-menu"></i>
              <span slot="title">法律咨询</span>
            </el-menu-item>
          </el-submenu>

          <!--        <el-menu-item index="/business/product">-->
          <!--          <i class="el-icon-menu"></i>-->
          <!--          <span slot="title">产品管理</span>-->
          <!--          -->
          <!--        </el-menu-item>-->

          <!--        <el-menu-item index="/business/contract">-->
          <!--          <i class="el-icon-menu"></i>-->
          <!--          <span slot="title">合同管理</span>-->
          <!--        </el-menu-item>-->
          <!--        <el-menu-item index="/business/LegalConsultation">-->
          <!--          <i class="el-icon-menu"></i>-->
          <!--          <span slot="title">法律咨询管理</span>-->
          <!--        </el-menu-item>-->
          <el-menu-item index="/business/user">
            <i class="el-icon-menu"></i>
            <span slot="title">用户管理</span>
          </el-menu-item>
        </el-menu>
      </el-aside>
      <!--    主要内容-->
      <el-main>
        <router-view></router-view>
      </el-main>
    </el-container>
  </div>
</template>

<script>
import NavigationBar from "@/components/NavigationBar";
export default {
  name: "Business",
  components: {NavigationBar},
  data(){
    return{
      activePath:"/business/order"
    }
  },
  watch:{
    $route(to,from){
      this.activePath = to.path;
    }
  }
}
</script>

<style scoped>
.business{
  height: 100%;
}
.el-container{
  height: calc(100% - 50px);
}
.el-menu{
  height: calc(100% - 40px);
}
.title{
  text-align: center;
  height: 40px;
  line-height: 40px;
  font-size: 16px;
  font-weight: bold;
  background-color: rgb(55,75,118);
  /*margin-bottom: 10px;*/
  color: white;
}
</style>
